﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Backend/Backend.Master" Inherits="System.Web.Mvc.ViewPage<IntroduceCompany.Administrator>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <meta name="description" content="" />
    <meta name="keywords" content="" />

<!-- Begin one column tab content window -->
    <div class="onecolumn">
        <div class="header">
            <span>Thông tin cá nhân</span>

        </div><br class="clear" />
        <div class="content">
            <% using (Html.BeginForm("AdminPageEdit", "Admin", FormMethod.Post)){%>
                <%= Html.AntiForgeryToken(IntroduceCompany.Util.AntiKey.EditSalt)%>
                <%= Html.ValidationSummary(true) %>

            <div class="display-label error">
                <div class="errorcontent">
                    <p><%= Html.ValidationMessage("NoticePage")%></p>
                    <p><%= Html.ValidationMessageFor(model => model.FullName) %></p>
                    <p><%= Html.ValidationMessageFor(model => model.Birthday) %></p>
                    <p><%= Html.ValidationMessageFor(model => model.Address) %></p>
                    <p><%= Html.ValidationMessageFor(model => model.Email) %></p>
                    <p><%= Html.ValidationMessageFor(model => model.Phone) %></p>
                </div>
            </div>

            <div>
                <div class="editor_left">
                    <label>Tên đăng nhập:</label><br />
                    <%= Html.TextBoxFor(model => model.UserName, new { maxlength = "20" })%>
                </div>
                <div class="editor_middle">
                    <label>Họ tên:</label><br />
                    <%= Html.TextBoxFor(model => model.FullName, new { maxlength = "100" })%>
                </div>
                <div class="editor_right">
                    <div class="editor_fl">
                        <label>Giới tính:</label><br />
                        <%= Html.DropDownListFor(model => model.GenderID, ViewData["Gender"] as SelectList, new { @style="width:130px;"})%>
                    </div>
                    <div class="editor_fr">
                        <label>Ngày sinh:</label><br />
                        <%= Html.TextBoxFor(model => model.Birthday, new { maxlength = "10", @style="width:128px;"})%>
                    </div>
                </div>
            </div><br class="clear"/><br />
            
            <div>
                <div class="editor_left">
                    <label>Mật khẩu hiện tại:</label><br />
                    <%= Html.Password("currentPass", null, new { maxlength = "20" })%>
                </div>
                <div class="editor_middle">
                    <label>Mật khẩu mới:</label><br />
                    <%= Html.Password("newPass", null, new { maxlength = "20" })%>
                </div>
                <div class="editor_right">
                    <label>Xác nhận mật khẩu mới:</label><br />
                    <%= Html.Password("confirmNewPass", null, new { maxlength = "20" })%>
                </div>
            </div><br class="clear"/><br />


            <div>
                <div class="editor_left">
                    <label>Email:</label><br />
                    <%= Html.TextBoxFor(model => model.Email, new { maxlength = "100" })%>
                </div>
                <div class="editor_middle">
                    <label>Điện thoại:</label><br />
                    <%= Html.TextBoxFor(model => model.Phone, new { maxlength = "20" })%>
                </div>
                <div class="editor_right">
                    <p style="padding:5px 0;"><label>Lần đăng nhập cuối:</label>
                    <%= IntroduceCompany.Util.GeneralClass.ConvertDate_1B(Model.LoginDate)%></p>
                    <p><label>Lần đăng xuất cuối:</label>
                    <%= IntroduceCompany.Util.GeneralClass.ConvertDate_1B(Model.LogoutDate)%></p>
                </div>
            </div><br class="clear"/><br />

            <div>
                <label>Địa chỉ:</label><br />
                <%= Html.TextBoxFor(model => model.Address, new { maxlength = "250" })%>
            </div><br class="clear"/><br />

            <%= Html.HiddenFor(model => model.AdminID) %>
            <%= Html.HiddenFor(model => model.UserName) %>

            <p>
                <input type="submit" value="Lưu" />
                <a href="<%= Url.Action("AdminPage","Admin", new { adminID = Model.AdminID }) %>"  class="buttonform">Làm Lại</a>
            </p>

        <% } %>
        </div>
    </div>
</asp:Content>
